A magnetic sensor device is used for detecting micro-magnetic patterns such as magnetic patterns that are formed in paper money. There are magnetic sensor devices inside which a magnetoresistive element is used, the resistance value of which changes according to the intensity of an applied magnetic field. In a magnetic pattern that is included in a paper-like medium such as a paper money, the remnant magnetization is weak. Therefore, in order to detect a magnetic pattern, it is necessary to provide a magnetoresistive element in environments where the magnetic field is strong, and furthermore, it is necessary to deliver the paper money near the magnetoresistive element.
However, in a non-contact type of magnetic sensor device, the test object and the magnetoresistive element are arranged so as to be in noncontact with each other. Therefore, there is a problem in that the amount of change in the resistance value of the magnetoresistive element is small, and thus the detection sensitivity of the magnetic pattern included in the test object is low. Moreover, in conventional magnetic sensor devices, there is a problem in that the detection sensitivity may vary due to assembly error of the magnetic sensor device or variation in the position where the test object passes.
Patent Literature 1 discloses technology for improving the detection sensitivity of a test object. In the technology disclosed in Patent Literature 1, the magnetic sensor device is composed of two magnetic sensors, with each being provided with a high-potential-side magnetoresistive element and a low-potential-side magnetoresistive element. The two magnetic sensors are such that the one high-potential-side magnetoresistive element faces the other low-potential-side magnetoresistive element, and are connected so as to output inverted signals. The signal that is outputted from each magnetic sensor undergoes differential amplification by an amplifier. As a result, the output signal from each magnetic sensor is such that the in-phase noise component is removed, the signal component is amplified and the S/N ratio is increased.
Moreover, Patent Literature 2 discloses a magnetic sensor device in which, by pressing the test object in contact with and moving the test object over the surface of a protective case, variation in the location where the test object passes is reduced. In this magnetic sensor, in order to expose the leads of the magnetoresistive element chip, an insulator film on which the leads are exposed is used. The exposed leads of the insulator film are connected to the electrodes of the magnetoresistive element chip inside a device hole where the insulating layer on the magnetoresistive element chip surface has been removed. A protective case is provided in order to protect the magnetoresistive element chip and the exposed leads. In order to insulate the magnetoresistive element chip from the protective case, an air gap is formed between the magnetoresistive element chip and the protective case.